package com.feign.client;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * Created by
 *  通过feign方式调用
 * @author touni
 * @date 2019/4/12
 * @time 17:19
 */
//@Component(value = "userClient")
@FeignClient(value = "user-service",fallback = UserClientImpl.class)
public interface UserClient {

    @GetMapping("/user/{id}")
    Object queryById(@PathVariable Integer id);



}
